<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>在线选课系统-用户登录</title>
<link rel="stylesheet" href="${pageContext.request.contextPath }/css/login.css" type="text/css"></link>
</head>
<body>

	<div class="login">
    <img src="${ pageContext.request.contextPath }/images/loginBg.jpg" alt="">
    <div class="content-container">
      <div class="content">
        <div class="form">
          <h2>登录</h2>
          <h4>欢迎来到在线选课系统</h4>
          <div>
          	<form action="${pageContext.request.contextPath}/LoginServlet" method="post">
     	        <input class="input" type="text" placeholder="请输入用户名" name="username" />
	            <input class="input" type="password" placeholder="请输入密码" value="123" name="password"/>
	            <div class="select input">
		            <select class="select" name="identity">
		            	<option value="-1">请选择身份</option>
		            	<option value="0">学生</option>
		            	<option value="1">教师</option>
		            	<option value="2">超级管理员</option>
		            </select>
	            </div>
	            <div class="btns">
	            	<input type="submit" class="btn" />
	            	<input type="reset" class="btn" />
	            </div>
          	</form>
          </div>
        </div>
        <div class="text">
	          <a href="${pageContext.request.contextPath}/view/register.jsp">前往注册</a>
	          <span>|</span>
	          <a href="#">忘记密码</a>
        </div>
        <%
		 	Object error = request.getAttribute("nullError");
		 	if (error != null)  out.print("<div style='width:100%;color: red;text-align:center;margin: 15px 0 15px 10px;font-size:19px;'><span>"+error+"请重新登录！</span><div>");
	  	%>
      </div>
    </div>
  </div>
</body>
</html>